// 导入request
import request from '../utils/request'
// 获取社区团购列表
export function getGroupBuy(params:any){
  return request.get("/api/yp/groupBuy",{params})
}
// 获取团购商品
export function getGroupBuyProduct(params:any){
  return request.get("/api/yp/groupBuyProduct",{params})
}
//获取标签
export function getTags(params:any){
  return request.get("/api/yp/tag",{params})
}
// 获取店铺数据
export function getShops(params:any){
  return request.get("/api/yp/shop",{params})  
}
// 获取商品
export function getProducts(params:any){
  return request.get("/api/yp/product",{params})
}
// 创建团购
export  function createGroupBuy(data:any){
  return request.post("/api/yp/groupBuy",data)
}
// 创建团购商品
export function createGroupBuyProduct(data:any){
  return request.post("/api/yp/groupBuyProduct",data)
}
// 修改团购
export function updateGroupBuy(data:any){
  return request.put("/api/yp/groupBuy",data)
}